/**
 * Created by Wang on 2015/12/5 0005.
 */

'use strict';
angular
  .module("myApp")
  .factory("$site", function(){
    var $site = {};
    $site.title = "Admin Home";
    return $site;
  })
  .controller('mainCtrl', ['$scope', '$site', function(scope, site) {
    scope.menuItems = ['Home', 'Articles', 'Comments', 'Users', 'System Manage', 'System Settings'];
    scope.siteTitle = site.title;
    scope.viewLoaded = function () {
      scope.siteTitle = site.title;
    }

  }]);

